#include <QCoreApplication>

enum Colors{black,red,green,blue};

//    结构体
struct product{
    int weight;
    double value;
    Colors color;
};


int main(int argc, char *argv[])
{
    QCoreApplication a(argc, argv);

    product laptop;
    qInfo()<<"Size"<<sizeof(laptop);

    laptop.color = Colors::green;
    laptop.value = 530.53;
    laptop.weight = 32;
    qInfo()<<"Color:"<<laptop.color;
    qInfo()<<"Value:"<<laptop.value;
    qInfo()<<"Weight:"<<laptop.weight;
//    qInfo()<<"Laptop:"<<laptop;
    qInfo()<<"Size"<<sizeof(laptop);

    return a.exec();
}
